<?php

$data = glob("./upload/*");

var_dump($data);
?>
<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
</head>
<body>
	<table border="1">
		<tr>
			<td>文件名</td>
			<td>文件大小</td>
			<td>文件时间</td>
			<td>文件操作</td>
		</tr>
		<?php foreach ($data as  $v) { ?>
		<tr>
			<td><?php echo basename($v); ?></td>
			<td><?php echo filesize($v); ?></td>
			<td><?php echo filemtime($v); ?></td>
			<td>
				<a href="del.php?url=<?php echo $v; ?>">删除</a>
				<a href="down.php?url=<?php echo $v; ?>">下载</a>
			</td>
		</tr>	
		<?php } ?>
	</table>
</body>
</html>
